package icu.thatyear.main.controller.base;

import cn.dev33.satoken.util.SaResult;
import icu.thatyear.main.service.ITzSysMenuService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 * 菜单管理 前端控制器
 * </p>
 *
 * @author Cjy
 * @since 2024-12-06
 */
@RestController
@RequestMapping("/tzSysMenu")
public class TzSysMenuController {
    private final ITzSysMenuService sysMenuService;

    @Autowired
    public TzSysMenuController(ITzSysMenuService sysMenuService) {
        this.sysMenuService = sysMenuService;
    }


    @GetMapping("/table")
    public SaResult getMenuList(){
        return SaResult.data(sysMenuService.list());
    }

}
